<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ include file="/jsp/common/common_include_for_server.jsp"%>
<s:a href="manage/article!saveOrUpdate">添加文章</s:a>
<form id="query_form" action="<%=request.getContextPath()%>/manage/article!list.action" method="post">
	分类：
			<select name="paramArticleType.articleTypeId">
				<option value="">---所有分类---</option>
				<s:iterator value="#application[@org.zhouhe.util.Constant@APPLICATION_KEY_ARTICLE_TYPE_LIST ]">
					<option style="font-weight:bold" value="${articleTypeId }" <s:if test="%{paramArticleType.articleTypeId == articleTypeId}">selected</s:if>><s:property value="name"/></option>
					<s:iterator value="articleTypes">
						<option value="${articleTypeId }" <s:if test="%{paramArticleType.articleTypeId == articleTypeId}">selected</s:if>  >&nbsp;&nbsp;<s:property value="name"/></option>
					</s:iterator>
				</s:iterator>
			</select><s:property value="#request.articleType.articleTypeId"/>
	行业：
			<select name="paramIndustry.industryId">
				<option value="">---所有行业---</option>
				<s:iterator value="#application[@org.zhouhe.util.Constant@APPLICATION_KEY_INDUSTRY_LIST ]">
					<option class="industry-l1" value="${industryId }" <s:if test="%{paramIndustry.industryId == industryId}">selected</s:if>><s:property value="name"/></option>
					<s:iterator value="industries">
						<option class="industry-l2" value="${industryId }" <s:if test="%{paramIndustry.industryId == industryId}">selected</s:if>  >　　<s:property value="name"/></option>
					</s:iterator>
				</s:iterator>
			</select>
	关键字：<s:textfield name="article.title" value="%{article.title}" size="20"></s:textfield>
	<s:hidden id="show_page" name="pageUtil.showPage" value="pageUtil.showPage"></s:hidden>
	<input type="button" value="查询" onclick="go(1, true)" />
</form>
<table border="1">
	<tr>
		<th>
			分类
		</th>
		<th>
			行业
		</th>
		<th>
			标题
		</th>
		<th>
			录入时间
		</th>
		<th>
			操作
		</th>
	</tr>
	<s:iterator value="pageUtil.pageData">
		<tr>
			<td>
				<s:property value="articleType.name" />
				<s:iterator value="articleArticleTypes" status="sts">
					<s:if test="articleType.articleType != null">
						<s:property value="articleType.articleType.name"/> &gt;&gt;
					</s:if>
					<s:property value="articleType.name"/><br/>
				</s:iterator>
			</td>
			<td>
				<s:iterator value="articleIndustries">
					<s:if test="industry.industry != null">
						<s:property value="industry.industry.name"/> &gt;&gt;
					</s:if>
					<s:property value="industry.name" /><br/>
				</s:iterator>
			</td>
			<td>
				<a href="article.action?article.articleId=${articleId }" target="_bank">
				<s:property value="title" />
				</a>
			</td>
			<td>
				<s:date name="createTime" format="yyyy-MM-dd HH:mm" />
			</td>
			<td>
				<s:a href="manage/article!saveOrUpdate.action?article.articleId=%{articleId}&pageUtil.showPage=%{pageUtil.showPage}">修改</s:a>
				<s:a href="manage/article!delete.action?article.articleId=%{articleId}&pageUtil.showPage=%{pageUtil.showPage}">删除</s:a>
			</td>
		</tr>
	</s:iterator>
</table>
<script type="text/javascript">
<!--
		function go(showPage, newSearch){
			$('#show_page').val(showPage);
			if(!newSearch){
				$('#query_form').get(0).reset();
			}
			$('#query_form').submit();
		}
	//-->
	</script>
<%@ include file="/jsp/common/common_include_for_pages.jsp"%>
